package com.wzw.springboot.principle.transaction.controller;

import com.wzw.springboot.principle.transaction.service.UserService;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author Wangzhiwen
 */
@RestController
@RequestMapping("/user")
public class UserController {

    @Resource
    private UserService userService;

    @PostMapping("/update")
    public Boolean updateUser() {
        return userService.updateUser();
    }

    @PostMapping("/asyncUpdate")
    public Boolean asyncUpdate() {
        return userService.asyncUpdateUser();
    }
}
